<?php

namespace yiike\store\merchant\models;

use Yii;
use \yiike\store\merchant\models\base\OrderGoods as BaseOrderGoods;
use yii\helpers\ArrayHelper;

/**
 * This is the model class for table "ims_ttyc_order_goods".
 */
class OrderGoods extends BaseOrderGoods
{

    public function behaviors()
    {
        return ArrayHelper::merge(
            parent::behaviors(),
            [
                # custom behaviors
            ]
        );
    }

    public function rules()
    {
        return ArrayHelper::merge(
            parent::rules(),
            [
                # custom validation rules
            ]
        );
    }


    /**
     * @return \yii\db\ActiveQuery
     */
    public function getOrderStore()
    {
        return $this->hasOne(OrderStore::className(), ['order_id' => 'order_id', 'store_id' => 'store_id']);
    }
}
